<!DOCTYPE html>
<html lang="zh_CN" xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.ultraq.net.nz/web/thymeleaf/layout">
<div class="table-responsive">
    <table class="table table-bordered">
        <thead>
        <tr>
            <th class="text-center" width="22%">订单号</th>
            <th class="text-center" width="10%">充值金额</th>
            <th class="text-center" width="7%">昵称</th>
            <th class="text-center" width="20%">用户(手机/邮箱/账号)</th>
            <th class="text-center" width="10%">支付时间</th>
            <th class="text-center" width="8%">支付类型</th>
            <th class="text-center" width="8%">支付状态</th>
            <th class="text-center" width="7%">操作</th>
        </tr>
        </thead>
    </table>
    <div class="J_V_tabContent table-xScrollWrap">
        <table class="table table-bordered table-hover table-xs-content">
            <tbody>
                <tr class="jqgfirstrow" role="row">
                    <th class="text-center" width="22%">&nbsp;</th>
                    <th class="text-center" width="10%">&nbsp;</th>
                    <th class="text-center" width="7%">&nbsp;</th>
                    <th class="text-center" width="20%">&nbsp;</th>
                    <th class="text-center" width="10%">&nbsp;</th>
                    <th class="text-center" width="8%">&nbsp;</th>
                    <th class="text-center" width="8%">&nbsp;</th>
                    <th class="text-center" width="7%">&nbsp;</th>
                </tr>
                <tr th:if="${#lists.isEmpty(dataMap['list'])}">
                    <td colspan="10" class="text-center">
                        <div class="noDataTipsBox">
                            <p><span class="c-4e fs16">亲，还没有数据~~~</span></p>
                        </div>
                    </td>
                </tr>
                <tr th:if="!${#lists.isEmpty(dataMap['list'])}" th:each="order : ${dataMap['list']}" th:attrappend="data-id=${order['id']}">
                    <td class="text-center" th:text="${order['orderNo']}"></td>
                    <td class="text-center" th:text="${order['realPrice']}"></td>
                    <td class="text-center">
                        <th:block th:if="!${#maps.isEmpty(order['user'])}">
                            <span th:text="${order['user']['nickname']}">—</span>
                        </th:block>
                        <span th:if="${#maps.isEmpty(order['user'])}">—</span>
                    </td>
                    <td class="text-center">
                        <th:block th:if="!${#maps.isEmpty(order['user'])}">
                            <span th:if="${order['user']['mobile']}==null or ${order['user']['mobile']}==''">—/</span>
                            <span th:if="${order['user']['mobile']}!=null and ${order['user']['mobile']}!=''" th:text="${order['user']['mobile']}+'/'"></span>
                            <span th:if="${order['user']['email']}==null or ${order['user']['email']}==''">—/</span>
                            <span th:if="${order['user']['email']}!=null and ${order['user']['email']}!=''" th:text="${order['user']['email']}+'/'"></span>
                            <span th:if="${order['user']['loginAccount']}==null or ${order['user']['loginAccount']}==''">—</span>
                            <span th:if="${order['user']['loginAccount']}!=null" th:text="${order['user']['loginAccount']}"></span>
                        </th:block>
                        <span th:if="${#maps.isEmpty(order['user'])}">—</span>
                    </td>
                    <td class="text-center" th:attrappend="id='order-pay-time-'+${order['id']}">
                        <span th:if="!${#strings.isEmpty(order['payTime'])}" th:text="${#strings.substring(order['payTime'],0,16)}"></span>
                        <span th:if="${#strings.isEmpty(order['payTime'])}">—</span>
                    </td>
                    <td class="text-center" th:attrappend="id='order-pay-type-box-'+${order['id']}">
                        <span th:if="${order['payType']}=='WEIXIN'">微信</span>
                        <span th:if="${order['payType']}=='ALIPAY'">支付宝</span>
                        <span th:if="${order['payType']}=='ACCOUNT'">账户支付</span>
                        <span th:if="${order['payType']}=='IOS'">IOS内购</span>
                        <span th:if="${order['payType']}=='FREE'">赠送</span>
                        <span th:if="${#strings.isEmpty(order['payType'])}">—</span>
                    </td>
                    <td class="text-center" th:attrappend="id='order-status-box-'+${order['id']}">
                        <span th:if="${order['orderStatus']}=='INIT'" class="label label-danger">未支付</span>
                        <span th:if="${order['orderStatus']}=='SUCCESS'" class="label label-info">已支付</span>
                        <span th:if="${order['orderStatus']}=='REFUND'"  class="label label-primary">已退款</span>
                        <span th:if="${order['orderStatus']}=='CANCEL'" class="label label-default">已取消</span>
                    </td>
                    <td class="text-center">
                        <a href="javascript:void(0)" class="c-master fs14 order-info-box" th:attrappend="data-id=${order['id']}" data-toggle="tooltip" data-placement="bottom" data-original-title="查看"><i class="fa fa-eye"></i></a>
                    </td>
                </tr>
            </tbody>
        </table>
    </div>
    <!-- 分页，开始 -->
    <div data-th-replace="layout/adminPage"></div>
    <!-- 分页，结束 -->
</div>
</html>